package com.controller;

import com.common.Result;
import com.entity.AttentionTopic;
import com.service.AttentionTopicService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * @Author：Luohuiyong
 * @Description:
 * @Date: Created in 17:12 2019/1/30
 */
@RestController
@RequestMapping("pcApi")
public class AttentionTopicController {

    @Autowired
    private AttentionTopicService attentionTopicService;

    /**
     * 分页查询
     * @param bean
     * @return
     */
    @ResponseBody
    @PostMapping(value = "/attention/topic/index", produces = {"application/json;charset=UTF-8"})
    public Result index(@RequestBody AttentionTopic bean){
        return attentionTopicService.index(bean);
    }

    /**
     * 新增数据
     * @param bean
     * @return
     */
    @ResponseBody
    @PostMapping(value = "/attention/topic/create", produces = {"application/json;charset=UTF-8"})
    public Result create(@RequestBody AttentionTopic bean){
        return  attentionTopicService.create(bean);
    }



}
